/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.tintuna.cca.property;

import java.lang.reflect.InvocationTargetException;
import java.util.Date;
import org.openide.nodes.Node.Property;
import org.openide.nodes.PropertySupport;
import org.tintuna.cca.data.Row;
import org.tintuna.cca.node.RowNode;

/**
 *
 * @author bsmith
 */
public class AmountProperty extends PropertySupport.ReadWrite<Double> {

    Row row;

    public AmountProperty(Row row) {
        super(RowNode.BALANCE_PROPERTY, Double.class, "Transaction balance", "The balance after the transaction");
        this.row = row;
    }

    @Override
    public Double getValue() throws IllegalAccessException, InvocationTargetException {
        return row.getBalance();
    }

    @Override
    public void setValue(Double t) throws IllegalAccessException, IllegalArgumentException, InvocationTargetException {
        throw new UnsupportedOperationException("Not supported yet.");
    }
}
